Recording and reproducing apparatus and recording method

ABSTRACT

A recording/reproducing apparatus is provided which can write continuously a file of large-capacity at high-speed. 
     A record area of HDD is provided with a disk cache area for temporarily storing data to be written. The disk cache area is defined as a area that is not used by a host apparatus ( 3 ) in an LBA space, and the disk cache area is disposed in an area with a high transfer rate such as an outer circumferential area of a disk ( 10 ). A file transferred from the host apparatus ( 3 ) is written in the disk cache area, and the file is transferred from the disk cache area to a usual user area during an idle period to release the disk cache area and prepare for next transfer data write.

This application is a 371 U.S. National Stage filing ofPCT/JP2004/014806, filed Sep. 30, 2004, which claims priority toJapanese Patent Application No. JP2003-345060, filed Oct. 2, 2003, bothof which are incorporated herein by reference.

TECHNICAL FIELD

The present invention relates to a recording/reproducing apparatus and arecording/reproducing method in which various data such as AV data ismanaged as files, and more particularly to a recording/reproducingapparatus and a recording method suitable when using as a recordingmedium a disk or the like having data transfer rates differed accordingto access positions of the disk.

BACKGROUND ART

A FAT file system is a file system used by external storage apparatus ofPC, such as a hard disk drive (HDD) and media using a solid state memoryas a recording medium (Memory Stick (registered trademark) manufacturedby Sony Corporation, SmartMedia (registered trademark) manufactured byToshiba Corporation, CompactFlash (registered trademark) manufactured bySanDisk Inc. and MultiMediaCard, etc.).

The FAT file system uses a FAT (File Allocation Table) indicating thateach file is located at which position of a recording medium, and twodata: a file attribute and a directory item indicating that each fileexists at which position of the directory.

An area dedicated to a FAT and a root directory is usually provided in arecording medium. A PC (Personal Computer) receives these informationnecessary for file access information.

A memory for constantly storing a copy of the contents of a FAT area ina storage medium is provided in a recording/reproducing apparatus. As ahost apparatus issues an access request command, FAT stored in thememory is referenced to determine an access position so that high-speedaccess is possible (for example, refer to Patent Document 1 (JapanesePatent Application Publication HEI-8-339661)).

If a spinning recording medium such as HDD is used, a transfer rate inan inner area is much slower than that in an outer area (about a halffor HDD). Although the FAT file system writes data continuously by usingan (outer) area having a fast transfer rate as much as possible, afterthe outer area is used completely, the inner area with a slow rate hasto be used by all means. If data write and erase are executedrepetitively, it becomes difficult to acquire a continuous empty area,and one file is recorded divisionally into a number of non-continuesclusters so that a transfer rate is lowered greatly (this is generallycalled fragmentation).

In either case, the transfer performance lowers as the time elapses.Particularly, if continuous imaging is performed in a high image qualitymode of a digital still camera, data write of large-capacity athigh-speed occurs in a short time and it is difficult to process thisdata write by using a presently used recording medium such as HDD andmemory card. There arise therefore problems such as loading a largebuffer in a camera and prolonging a wait time for writing again in arecording medium after continuous imaging.

The present invention has been made in order to solve these issues andaims to provide a recording/reproducing apparatus and a recordingmethod, which are capable of writing a large-capacity file continuouslyat high-speed.

DISCLOSURE OF THE INVENTION

In order to achieve this object, a recording/reproducing apparatus ofthe present invention has: a recording medium having different transferrates in accordance with record positions; and control means forcontrolling a temporary record area to be released by writing datatransferred from a host apparatus into the temporary record area withuse of a predetermined record area of the recording medium as atemporary record area, and transferring the data from the temporaryrecord area to another record area having a lower transfer rate thanthat of the temporary record area during an idle period.

According to the present invention, the high-speed record area of therecording medium is used as the temporary record area, data transferredfrom the host apparatus is written in the temporary record area, and thedata is transferred from the temporary record area to the other recordarea having a lower transfer rate than that of the temporary record areaduring an idle period to release the high-speed record area and preparefor the next transfer data write. Therefore, a transfer rate as viewedfrom the host apparatus can be improved considerably.

The recording/reproducing apparatus of the present invention may furtherhave a memory for storing a table for managing address information onfiles in the recording medium, wherein the control means may beconfigured to read the table in the recording medium into the memory inresponse to a predetermined mode switch command from the host apparatus,and checks an empty area in the temporary record area or an empty areain the other record area with reference to the table stored in thememory. More specifically, according to the present invention, a load ofthe host apparatus can be reduced and high-speed operation can berealized, because a process of checking the empty area in the temporaryrecord area or the other record area is executed in therecording/reproducing apparatus by referring to the table, not dependingupon the process in the host apparatus.

Further, in the recording/reproducing apparatus of the presentinvention, if an access request for the storage apparatus from the hostapparatus does not occur after the lapse of a predetermined time orlonger, the control means may control to release the temporary recordarea by transferring data from the temporary record area to the otherrecord area having a lower transfer rate than that of the temporaryrecord area. In this case, data transfer from the temporary record areato the other record area can be executed fast without contention of theprocess to be executed in response to an access request from the hostapparatus.

Furthermore, in the recording/reproducing apparatus of the presentinvention, the control means may control to compress data and write thedata into the temporary record area, and decompress the compressed databefore the data is transferred to the other record area. It is thereforepossible to improve a use efficiency of the temporary record area andsuppress a capacity loss of the user area to be caused by the temporaryrecord area when the temporary record area is used as an area unable tobe observed from the user.

In addition, a recording/reproducing method according to another aspectof the present invention for recording data in a recording medium havingdifferent transfer rates in accordance with record positions, the methodhas steps of: writing data transferred from a host apparatus into thetemporary record area with use of a predetermined record area of therecording medium as a temporary record area; and releasing the temporaryrecord area by transferring the data from the temporary record area toanother record area having a lower transfer rate than that of thetemporary record area during an idle period.

According to the present invention, the high-speed record area of therecording medium is used as the temporary record area, data transferredfrom the host apparatus is written in the temporary record area, and thedata is transferred from the temporary record area to the other recordarea having a lower transfer rate than that of the temporary record areaduring an idle period to release the high-speed record area and preparefor the next transfer data write. Therefore, a transfer rate as viewedfrom the host apparatus can be improved considerably.

The recording method of the present invention may further have steps of:reading a table in the recording medium into a memory of arecording/reproducing apparatus in response to a predetermined modeswitch command from the host apparatus; and checking an empty area inthe temporary record area or an empty area in the other record area withreference to the table stored in the memory. According to the presentinvention, a load of the host apparatus can be reduced and high-speedoperation can be realized, because a process of checking the empty areain the temporary record area or other record area is executed in therecording/reproducing apparatus by referring to the table, not dependingupon the process in the host apparatus.

Further, in the recording method of the present invention, if an accessrequest for the storage apparatus from the host apparatus does not occurafter the lapse of a predetermined time or longer, the temporary recordarea may be released by transferring data from the temporary record areato the other record area having a lower transfer rate than that of thetemporary record area. In this case, data transfer from the temporaryrecord area to the other record area can be executed fast withoutcontention of the process to be executed in response to an accessrequest from the host apparatus.

Furthermore, the recording method of the present invention may havesteps of: compressing data to be written into the temporary record area;and decompressing the compressed data read from the temporary recordarea before the data is transferred from the temporary record area tothe other record area. It is therefore possible to improve a useefficiency of the temporary record area and suppress a capacity loss ofthe user area to be caused by the temporary record area when thetemporary record area is used as an area unable to be observed from theuser.

BRIEF DESCRIPTION OF THE DRAWINGS

FIG. 1 is a diagram showing the structure of a recording/reproducingapparatus according to an embodiment of the present invention.

FIG. 2 is a diagram showing an area map of a disk address space of therecording/reproducing apparatus shown in FIG. 1.

FIG. 3 is a flow chart illustrating an operation sequence of data writeto HDD.

FIG. 4 is a diagram showing an example of a command for settingparameters for data write.

BEST MODE FOR CARRYING OUT THE INVENTION

An embodiment of the present invention will be described below withreference to the accompanying drawings.

FIG. 1 is a diagram showing the structure of a recording/reproducingapparatus according to the embodiment of the present invention.

This recording/reproducing apparatus is a hard disk drive (hereinaftercalled “HDD”) 1 using a hard disk (hereinafter called “disk”) 10 and,adopts as a file system an MS-DOS compatible FAT file system.

The HDD 1 is connected to a host apparatus 3 such as an AV apparatus viaan interface 2 such as IDE (Integrated Drive Electronics), SCSI (SmallComputer System Interface), FC (Fibre Channel) and USB (Universal SerialBus). An interface control unit 4 of the HDD 1 receives a command issuedfrom the host apparatus 3 via the interface 2, comprehends its contentsand notifies a CPU 5 (Central Processing Unit) in the HDD 1. Inaccordance with the notified contents, the CPU 5 sets commands andparameters necessary for a hard disk control unit 6, a read/writechannel unit 7 and a servo control unit 8 to execute their operation.

The servo control unit 8 controls driving of a spindle motor 9 fordriving and rotating the disk 10 and a voice coil motor 11 for feeding ahead (not shown) for reading/writing signals from/to the disk 10 in aradial direction of the disk 10, to thereby move the head topredetermined track and sector. The read/write channel unit 7 encodes(modulates) user data sent during data write to the disk 10 into adigital bit string suitable for the characteristics of arecording/reproducing system. The read/write channel unit 7 removes highfrequency noises from reproduction signals read from the head duringdata read, converts analog signals into digital signals, estimates databy using a maximum likelihood decoding method, and thereafterdemodulates to reproduce user data.

The hard disk control unit 6 manages data transfer among a buffer memory12, the read/write channel unit 7 and the interface control unit 4, andexecutes a process regarding the format of data. In this case, encodingand error detection by error correction codes and a process regardingerror correction are also executed.

FIG. 2 is a diagram showing an area map of a disk address space. Aminimum unit of data write to the HDD 1 is called a sector whose size isusually 512 bytes. The HDD 1 manages a storage area of the disk 10 inthe sector unit by using three parameters: a physical address, aphysical sector number, a logical sector number. The physical address isconstituted of three parameters: a surface number, a track number and asector number. The physical sector number is the numbers of all sectorssequentially numbered in the order from the outer area of the disk 10 tothe inner area. The logical sector number is an address assigned to adefect sector unable to read/write, by a substitution process.

On the other hand, the host apparatus 3 accesses the disk 10 by using alogical block address (LBA). The file system for managing files uses onecluster constituted of a plurality of (N) sectors as a read/writeminimum unit. A FAT (File Allocation Table) is a table havinginformation therein on how each file is stored in clusters. A filesystem which performs management by using FAT is called a FAT filesystem. In the following description, it is assumed that a clusteraddress is obtained by simply dividing LBA by N, where N=16 (onecluster=8 Kbyte).

The storage area of the HDD 1 is usually divided into three areas: asystem area, a user area and an HDD system area. The system area anduser area are allocated in an LBA space as viewed from the hostapparatus 3.

The system area is constituted of two areas; a master boot record and aFAT area. The master boot record is a sector at LBA 0 as viewed from thehost apparatus 3, and records a boot strap code and a partition table.

The user area is constituted of a directory area for managing fileinformation and a data area of actual data (In FAT 32 or before, only aroot directory belongs to the system area). The directory area stores,as directory information A, a file name, an extension, an attribute, alatest update time, a start cluster address, a file size and the like,respectively of each directory (each file).

The HDD system area is used for the CPU 5 in the HDD 1 to store bootcodes and various tables, or for an area for the substitution process.Generally, the host apparatus does not use the HDD system area so thatthis area is omitted in FIG. 2.

In this embodiment, an area is set for temporarily storing data to bewritten. This area corresponds to an area (256 MByte) at logical sectornumbers from 00000h to 7FFFF shown in FIG. 2. Therefore, the logicalsector number of the master boot record is 80000h. In the following, thearea for temporarily storing data to be written is called a disk addressspace. In the LBA space, the disk cache area is disposed in a spaceafter F00000h which area the host apparatus 3 does not use (data area isup to 9FFFFF). A cluster address is defined also for this disk cachearea.

In recent HDDs, zone bit recording is generally performed in which adisk is divided into a plurality of zones (e.g., 10 to 20 zones) andeach zone uses the same write frequency and same recording/reproducingparameters (coefficients of a waveform equivalent filter, etc.). Ifwrite (read) is performed only in one zone, it is not necessary tochange parameters so that an efficiency is improved. Therefore, the sizeof the disk cache area is determined by considering the zone size.

Next, with reference to FIG. 3, description will be made on an operationof data write to the HDD 1.

Data write to the HDD 1 by using the disk cache area is executed whilethe HDD 1 manages address information for file management. Thisoperation mode is called an AV mode hereinafter and a normal operationmode is called a PC mode hereinafter.

First, the host apparatus 3 updates the contents of the FAT area of thedisk 10 in the HDD 1 to latest contents, and thereafter issues a commandof transferring to the AV mode from the PC mode. When the CPU 5 in theHDD 1 knows via the interface control unit 4 an instruction of transferto the AV mode (Step 301), the CPU 5 loads the contents of the FAT areain the disk 10 into a memory 13 (Step 302), and sets a flag indicatingan execution state of the AV mode to notify the host apparatus 3 oftransfer to the AV mode (Step 303).

When a particular write request operation such as continuous imaging bya digital camera is executed in the host apparatus 3, the host apparatus3 determines a file name (File 1) of content data to be written, newlyforms directory items and writes the items in the HDD 1. The directoryitems written at this time are only a start cluster address and a latestupdate time, which are incomplete as directory items.

The HDD 1 references FAT retained in the memory 13, selects a propercluster from empty clusters, and writes the directory information in theselected cluster (Step 304). After the directory information is written,the address is notified to the host apparatus 3.

Next, the host apparatus 3 sets parameters necessary for writing contentdata. Specifically, a start cluster address, access size and the like ofa file are determined. Although the host apparatus 3 defers managementof FAT to HDD, the start cluster address is required to be shared inorder to identify the file. FIG. 4 shows an example of the command (SetRec Parameter) for executing sharing. The command is defined as a vendorunique command of FAT, and executed only once prior to writing the file.

Of bits defined in a Feature register in the command, an OP (OuterPosition) and an IP (Inner Position) designate from which of the outerside or inner side of the disk 10 the HDD 1 takes the record startcluster. If bits of both OP and IP are 0, a start cluster address set ina Sector Count register or the like becomes valid.

In order to execute data write to the HDD 1 by using the disk cachearea, the host apparatus 3 notifies the HDD 1 of use permission of thedisk cache area in the file unit. To this end, the command is executedby setting “1” to a QW and OP, and notifies the host apparatus 3 of afirst searched empty cluster as a start cluster address (Step 305).

As the HDD 1 determines from the command issued from the host apparatus3 that the disk cache area can be used (Steps 306 and 307), HDD searchessequentially an empty cluster in the disk cache area starting from thetop of the disk cache area to select a longest continuous empty area.The HDD 1 records the start cluster address of the selected empty areatogether with the record start cluster address notified to the hostapparatus 3. For example, in the example shown in FIG. 2, the startcluster address of the empty area is LBA F00000h (PLBA 000000). Sincedata in the disk cache area is copied (moved) to the user area, most ofthe disk cache area are in an unused (empty) state.

Thereafter, the host apparatus writes sequentially data of the file in aset access size unit (Steps 308 and 309). At this time, although data isnot written in the cluster at the address notified to the host apparatus3, a used flag (e.g., EOF) is set to FAT.

Data sent from the host apparatus 3 is once stored in the buffer memory12, and formatted by the hard disk control unit 6, sent thereafter tothe read/write channel unit 7, and written in the selected cluster (B inFIG. 2) in the disk cache area. In this case, if the CPU 5 of the HDD 1or the hard disk control unit 6 has a sufficient ability, data iscompressed to reduce a write amount to the disk 10 so that a transferrate as viewed from the host apparatus 3 can be improved.

Each time data write of one access size unit is completed, FAT in thememory 13 is renewed by using the cluster address of the disk cache areamapped on the LBA space. In FIG. 2, the cluster at the cluster addressF0000h is the start cluster, and since the data write is executedcontinuously thereafter, F000h is set to the FAT item at the addressF0000h, F0002h is set to the FAT item as the address F0001h, and EOF(0FFFFFFFh in FAT32) is set at the last F000Dh.

After the file is completely written in the disk 10, the host apparatus3 updates the directory items of the disk 10 as for the latest updatetime and start cluster address. Thereafter, the host apparatus 3instructs the HDD 1 to write FAT in the memory 13 to the disk 10 (Step310).

Thereafter, if write or read does not occur after the lapse of a presettime or longer (if Idle) (YES at Step 312), then the HDD 1 copies datain the disk cache area to the user area (C in FIG. 2) (Step 313). Sincethe start cluster address has already notified to the host apparatus 3,data write starts at this address. Thereafter, FAT in the memory 3 isreferenced to sequentially search an empty cluster in the user area inaccordance with designation by IP and OP, and data is written in theempty cluster immediately after the empty cluster is found.

For example, in the example shown in FIG. 2, first the cluster at anaddress F0000h is copied to 01234h. At this time, the FAT item at theaddress 01234h is set to F0001h, and the cluster at the address F0000his set to an unused state (0000000h in FAT32). Next, since the clusterat an address 01235h is empty, the cluster at the address F0001h iscopied to the empty cluster. 01235h is set to the FAT item at an address01234h, F0002h is set to the FAT item at the address 01235h, and theunused state is set to the FAT item at the address F0001h. Similarly,clusters down to the address F000Dh are sequentially copied down to anaddress 01240h.

Accordingly, FAT is also updated (Step 314) to set the unused state tothe clusters down to F000Dh, and EOF (0FFFFFFFh) is set to the FAT itemat the cluster address 01240h at which the last portion of the file isentered.

If the data was compressed, the original data is recovered and written.If the command of transferring to the PC Mode from the AV mode is issuedfrom the host apparatus 3 during copy, the host apparatus 3 is notifiedof that the process is not still completed, to thereby intercepttransfer of the operation mode.

The description has been made by using HDD by way of specific example.The present invention is also applicable to storage media whose transferrate changes in accordance with an access position, such as opticaldisks including a CD (Compact Disc) and DVD (Digital Versatile Disc),storage devices using semiconductor memories as a medium and the like.The types of file systems optimum in the present invention are notlimited to a FAT file system, but any other file systems can also beadopted if the file systems manage data as files.

According to the recording/reproducing apparatus of the embodimentdescribed above, data write of high-speed and large-capacity can beexecuted stably at a maximum transfer rate of the storage apparatus.Particularly in the case of a hard disk drive, there is a twice transferrate difference at a maximum between each zone, and fragmentation existsin practice. Therefore, an effective write transfer rate is about onethird to one fourth of the maximum value. Data write is thereforepossible generally at a maximum performance. Since the transfer rate ofthe recording/reproducing apparatus is improved, for example, a waittime after continuous imaging by a digital camera can be shortenedwithout providing a large buffer on the host side.

The present invention is not limited only to the above-describedembodiment, but it is obvious that various modifications are possible inthe range not departing from the gist of the present invention.

INDUSTRIAL APPLICABILITY

According to the recording/reproducing apparatus and recording method ofthe present invention, a file of large-capacity can be writtencontinuously at high-speed, and advantageous effects can be obtained,for example, a wait time after continuous imaging by a digital cameracan be shortened without providing a large buffer on the host side.

1. A recording/reproducing apparatus, characterized by comprising: arecording medium having different transfer rates in accordance withrecord positions; and control means for controlling a temporary recordarea to be released by writing data transferred from a host apparatusinto the temporary record area with use of a predetermined record areaof the recording medium as the temporary record area, and transferringthe data from the temporary record area to another record area having alower transfer rate than that of the temporary record area during anidle period, wherein the control means reads a table in the recordingmedium into a memory storing the table for managing address informationon a file in the recording medium in response to a switch command fromthe host apparatus for switching to a write mode with use of thetemporary record area, checks an empty area in the temporary record areaor in the another record area with reference to the table stored in thememory, and notifies a write start address of the another record area tothe host apparatus.
 2. The recording/reproducing apparatus according toclaim 1, characterized in that if an access request for the storageapparatus from the host apparatus does not occur after the lapse of apredetermined time or longer, the control means controls to release thetemporary record area by transferring data from the temporary recordarea to the other record area having a lower transfer rate than that ofthe temporary record area.
 3. The recording/reproducing apparatusaccording to claim 1, characterized in that the control means compressesdata and writes the data into the temporary record area, anddecompresses the compressed data before the data is transferred to theother record area.
 4. A recording method for recording data into arecording medium having different transfer rates in accordance withrecord positions, characterized by comprising the steps of: writing datatransferred from a host apparatus into a temporary record area with useof a predetermined record area of the recording medium as the temporaryrecord area; releasing the temporary record area by transferring thedata from the temporary record area to another record area having alower transfer rate than that of the temporary record area during anidle period; reading the table in the recording medium into a memory ina recording/reproducing apparatus in response to a switch command fromthe host apparatus for switching to a write mode with use of thetemporary record area; and checking an empty area in the temporaryrecord area or in the another record area with reference to the tablestored in the memory.
 5. The recording method according to claim 4,characterized in that: if an access request for the storage apparatusfrom the host apparatus does not occur after the lapse of apredetermined time or longer, the temporary record area is released bytransferring data from the temporary record area to the another recordarea having a lower transfer rate than that of the temporary recordarea.
 6. The recording method according to claim 4, characterized byfurther comprising the steps of: compressing data to be written into thetemporary record area; and decompressing the compressed data read fromthe temporary record area at the time of transferring the data from thetemporary record area to the another record area.